import React from 'react'

class UserSettingTools extends React.Component {

  constructor(props) {
    super(props)
  }

  onDataSearch(event) {
    var input = event.target;
    var value = $(input).val();
    this.props.onDataSearch(value)
  }

  render() {
    return (
      <div className="demo-setting-tools row">

        <div className="col-sm-2 col-lg-1 col-xs-2 col-xs-offset-7 col-sm-offset-7 col-lg-offset-8 create-button">
          <button type="button" className="btn-create f-dn" 
                  onClick={(event)=>this.props.onCreateClick()}>新建</button>
        </div>
        {
          // <div className="col-sm-3 col-lg-2 f-dn refresh-button">
          //   <button type="button" className="btn-refresh"
          //           onClick={(event)=>this.props.onCreateClick()}><i className="ti-reload"></i>同步JDE业主信息</button>
          // </div>
        }

        <div className="col-sm-3 col-xs-3">
          <div className="input-group search-group">
            <i className="ti-search"></i>
            <input type="text" className="form-control" placeholder="请搜索户号"
                    onChange={(event)=>this.onDataSearch(event)}/>
          </div>
        </div>


      </div>
    )
  }

}

export default UserSettingTools
